﻿using DevExpress.ExpressApp;
using DevExpress.ExpressApp.Editors;

namespace EasyXaf.DynamicForm.Blazor;

public sealed class DynamicFormBlazorModule : ModuleBase
{
    public DynamicFormBlazorModule()
    {
        RequiredModuleTypes.Add(typeof(DynamicFormModule));
    }

    protected override void RegisterEditorDescriptors(EditorDescriptorsFactory editorDescriptorsFactory)
    {
        base.RegisterEditorDescriptors(editorDescriptorsFactory);

        editorDescriptorsFactory.RegisterPropertyEditorAlias(nameof(DynamicFormEditor), typeof(string), false);
        editorDescriptorsFactory.RegisterPropertyEditor(nameof(DynamicFormEditor), typeof(string), typeof(DynamicFormEditor), false);
    }
}
